package com.wswy.wzcx.utils

import android.support.v4.app.FragmentManager

object FragUtils {

    @JvmStatic
    fun removeAll(fm:FragmentManager){
        kotlin.runCatching {
            fm.beginTransaction().let {ft ->
                fm.fragments?.forEach {
                    ft.remove(it)
                }
                ft.commitNowAllowingStateLoss()
            }
        }

    }

}